Step 5: Create buttons and label
Display=new JLabel("");
Display.setBounds(30, 50, 540, 40);
Display.setBackground(Color.orange);
Display.setOpaque(true);
Display.setHorizontalAlignment(SwingConstants.RIGHT);
Display.setForeground(Color.red);
jf.add(Display);
Sevenbutton=new JButton("7");
Sevenbutton.setBounds(40, 150, 50, 50); //button7
Sevenbutton.addActionListener(this);
jf.add(Sevenbutton);
Eightbutton=new JButton("8");
Eightbutton.setBounds(100, 150, 50, 50); //button8
Eightbutton.addActionListener(this);
jf.add(Eightbutton);
ninebutton=new JButton("9");
ninebutton.setBounds(160, 150, 50, 50); //button9
ninebutton.addActionListener(this);
jf.add(ninebutton);
fourbutton=new JButton("4");
fourbutton.setBounds(40, 230, 50, 50); //button4
fourbutton.addActionListener(this);
jf.add(fourbutton);
fivebutton=new JButton("5");
fivebutton.setBounds(100, 230, 50, 50); //button5
fivebutton.addActionListener(this);
jf.add(fivebutton);
sixbutton=new JButton("6");
sixbutton.setBounds(160, 230, 50, 50); //button6
sixbutton.addActionListener(this);
jf.add(sixbutton);
onebutton=new JButton("1");
onebutton.setBounds(40, 310, 50, 50); //button1
onebutton.addActionListener(this);
jf.add(onebutton);
twobutton=new JButton("2");
twobutton.setBounds(100, 310, 50, 50); //button2
twobutton.addActionListener(this);
jf.add(twobutton);
threebutton=new JButton("3");
threebutton.setBounds(160, 310, 50, 50); //button3
threebutton.addActionListener(this);
jf.add(threebutton);
dotbutton=new JButton(".");
dotbutton.setBounds(40, 390, 50, 50); //button.
dotbutton.addActionListener(this);
jf.add(dotbutton);
zerobutton=new JButton("0");
zerobutton.setBounds(100, 390, 50, 50); //button0
zerobutton.addActionListener(this);
jf.add(zerobutton);
equalbutton=new JButton("=");
equalbutton.setBounds(280, 390, 60, 60); //button=
equalbutton.addActionListener(this);
jf.add(equalbutton);
divisionbutton=new JButton("/");
divisionbutton.setBounds(220, 150, 50, 50); //button/
divisionbutton.addActionListener(this);
jf.add(divisionbutton);
multipicationbutton=new JButton("*");
multipicationbutton.setBounds(220, 230, 50, 50); //button*
multipicationbutton.addActionListener(this);
jf.add(multipicationbutton);
minesbutton=new JButton("-");
minesbutton.setBounds(220, 310, 50, 50); //button-
minesbutton.addActionListener(this);
jf.add(minesbutton);
pulsebutton=new JButton("+");
pulsebutton.setBounds(220, 390, 50, 50); //button+
pulsebutton.addActionListener(this);
jf.add(pulsebutton);
clearButton =new JButton("clear");
clearButton.setBounds(160, 390, 50, 50);
clearButton.addActionListener(this);
jf.add(clearButton);
SquareButton =new JButton("Square");
SquareButton.setBounds(280, 150, 50, 50);
SquareButton.addActionListener(this);
jf.add(SquareButton);